#include<bits/stdc++.h>

using namespace std;
int Q[1000], head = 0, tail = -1;//Q[head,tail]
int main() {

    for (int i = 0; i < 10; i++)Q[++tail] = i;
    while (head <= tail) {
        cout << Q[head] << endl;
        ++head;
    }
    return 0;
}
